smpboot.h, io_apic.c:
Round robin allocate IRQs to processors on SMP.
UNEXPECTED_IO_APIC();
}
-#if 0
printk(KERN_DEBUG ".... IRQ redirection table:\n");
printk(KERN_DEBUG " NR Log Phy Mask Trig IRR Pol"
entry = irq_2_pin + entry->next;
}
printk("\n");
-#endif
}
printk(KERN_INFO ".................................... done.\n");
return cpu_online_map;
}
#else
-#define target_cpus() (0x01)
+/* KAF Xen: Round-robin allocate IRQs to CPUs. */
+static inline int target_cpus(void)
+{
+ static unsigned int cpu_field = 1;
+ do {
+ cpu_field <<= 1;
+ if ( cpu_field == 0x100 ) cpu_field = 1; /* logical field == 8 bits */
+ } while ( (cpu_field & cpu_online_map) == 0 );
+ return cpu_field;
+}
#endif
#endif